<template>
  <div>
    <div class='title2'>
      <span class='dd-c_o'>| </span> 取餐故障
    </div>
    <div class="question dd-column">
      <div v-for="(item,index) in arrs" :key="index" class="dd-row dd-h-2side dd-v-center" @click="gotoAnswer(item)">
        <div class="title">{{item.q}}</div>
        <div class="img"><img src="@/assets/img/right.png" alt="》" /></div>
      </div>
    </div>
    
    <div class="model" v-show="modelBool" >
      <div class="kuai dd-column ">
        <div class="close dd-row dd-h-right">
          <div class="closeDiv">
            <img class="closeImg" @click="close" src="@/assets/img/wrong.png" alt="x">
          </div>
        </div>
        <div class="content">
          <Answer :qa="answerData">
          </Answer>
        </div>
      </div>
    </div>
  </div>

</template>
<script>
import Answer from "@/components/My/myOrderDetails/answer/Answer";

export default {
  data() {
    return {
      arrs: [
        {
          q: "机器不做面1111",
          a:
            "刚才卡了不好意思刚才按时打算大所打算的撒的撒的撒一一按时的撒按时的撒的撒一一按时的撒按时的撒的撒一一按时的撒按时的撒111"
        },
        {
          q: "扫码没反应2222",
          a:
            "刚才卡了不好意思刚才卡了不好意思的撒一一按时的撒按时的撒的撒一一按时的撒按时的撒的撒一一按时的撒按时的撒222"
        }
      ],
      answerData: {},
      modelBool: false
    };
  },
  methods: {
    gotoAnswer(_item) {
      console.log(_item);
      this.answerData = _item;
      this.modelBool = true;
    },
    close(e) {
      this.modelBool = false;
    }
  },
  components: {
    Answer
  }
};
</script>
<style scoped>
.title2 {
  font-size: 12pt;
  font-weight: bold;
  margin: 5pt 2pt;
}
.question > div {
  border-bottom: 1pt solid #f1f1f1;
  font-size: 11pt;
  padding: 5pt;
  background: #ccc;
  height: 30pt;
}
.question > div:last-child {
  border: 0;
}
.question .title {
  font-size: 11pt;
  font-weight: normal;
}
.img {
  width: 14pt;
  height: 14pt;
}
.img > img {
  width: 14pt;
  height: 14pt;
}

/* 模态框 */
.model {
  position: fixed;
  top: 0;
  bottom: 0;
  right: 0;
  left: 0;
  background: rgba(0, 0, 0, 0.5);
}
/* 中间部分 */
.kuai {
  background: #f1f1f1;
  /* min-height: 200pt; */
  width: 94%;
  border-radius: 5pt;
  margin:100pt 3%;
  padding-bottom:10pt;
}
.kuai .close .closeDiv {
  width: 20pt;
  height: 20pt;
}

.kuai .close .closeDiv .closeImg {
  width: 20pt;
  height: 20pt;
}
</style>
